-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Utilities/ImageTools #327
Utilities/ImageTools #327
Conversation
9e088a8
to
2d2b0f8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Godo job!
Another addition, would be to compress/reduce size to a max size, eg. if server expects an image that is max 1MB, a nice method would be
func compress(image: UIImage, toMaxKbSize size: CGFloat) throws -> Data
Also, lets use Swift syntax with labeled parameters? Its such a great concept Swift offers, its really a shame we omit it, feels like a step back 😅
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work 👌
e75e9c1
to
7b85feb
Compare
7b85feb
to
4eacbe2
Compare
A set of image tools bundled in a handy
UIImage
extension. Some methods depends on the Kingfisher library, therefore it needs to be installed in the project in order to leverage them.